October 2020

This replication package contains material for "Do Online Newspapers Promote or Undermine Nation-Building in Divided Societies? Evidence From Africa" by Evan Lieberman and Andrew Miller.

The material includes the following:

analysis_code: this R script has the code for producing the tables and figures in the article and in the supplementary information appendix. *Note that the fixed effects models may take several days to run.*

data: the material includes raw data scraped from the Vanguard News site (vangaurd_2016_articles_RAW.csv, vangaurd_2016_authors_RAW.csv, & vangaurd_2016_comments_RAW.csv), the cleaned data used for analyzing the Nigeria headlines/comments (nigeria_data.RData), the cleaned data used for analyzing the South Africa headlines/comments (south_africa_data.RData). Note that the Nigeria Afrobarometer data can be downloaded here: https://afrobarometer.org/data/nigeria-round-6-data-2015. 

nigeria_cleaning_code: this R script cleans the raw Nigeria headline/comment data to create the nigeria_data.RData file. (The South Africa data was pulled from a pre-cleaned dataset containing multiple countries.) 

functions: the material includes R scripts for functions used to produce the tables in the main article/supplementary information (commarobust.R & stargazer_helpers.R)

Please contact Andrew Miller (millera@usna.edu) with questions.